const pkg = require('./package')


module.exports = {
  mode: 'universal',

  /*
  ** Headers of the page
  */
  head: {
    title: pkg.name,
    meta: [
      { charset: 'utf-8' },
      { name: 'viewport', content: 'width=device-width, initial-scale=1' },
      { hid: 'description', name: 'description', content: pkg.description }
    ],
    link: [
      { rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }
    ],
    script: [
     
    ]
  },

  /*
  ** Customize the progress-bar color
  */
  loading: { color: '#fff' },
  router: {
    middleware: ['i18n']
  },
  /*
  ** Global CSS
  */
  css: [
  ],

  /*
  ** Plugins to load before mounting the App
  */
  plugins: [
    '~/plugins/i18n.js',
    '~/plugins/jsBridge',
    '~/plugins/mint'
    // '~/plugins/vant'
    // {
    //   src: '~/plugins/i18n.js',
    //   ssr: true
    // },
    // {
    //   src: '~/plugins/jsBridge',
    //   ssr: true
    // }
    // {
    //   src: '~/plugins/vux-plugins',
    //   ssr: false
    // },
    // {
    //   src: '~/plugins/vux-components',
    //   ssr: true
    // }
  ],

  /*
  ** Nuxt.js modules
  */
  modules: [
  ],

  /*
  ** Build configuration
  */
  build: {
    /*
    ** You can extend webpack config here
    */
    // extend(config, ctx) {}
    // vendor: ['vant'],
    // babel: {
    //   plugins: ['transform-vue-jsx', ['component', {
    //       libraryName: 'vant',
    //       styleLibraryName: 'vant-css',
    //       style: true
    //     }]]
    //   }
    vendor: [
      'mint-ui'
    ],
    babel: {
      "plugins": [
        ["component", [{
          "libraryName": "mint-ui",
          "style": true
        }]]
      ]
    },
    "comments": true
  }
}
